# Maintainer: Marian Buschsieweke <marian.buschsieweke@ovgu.de>
# Contributor: Marian Buschsieweke <marian.buschsieweke@ovgu.de>
pkgname=enjoy
pkgver=0.3
pkgrel=1
pkgdesc="daemon to map joystick events to mouse/key events"
url="https://github.com/cjacker/enjoy"
arch="all"
license="MIT"
source="
	$pkgname-$pkgver.tar.gz::https://github.com/cjacker/enjoy/archive/refs/tags/v$pkgver.tar.gz

	0001-fix-printf-format-specifier.patch
	0002-fix-setting-timestamp-of-input-event.patch
	correct_udev_rules_path.patch
	"
makedepends="linux-headers"
options="!check" # no unit tests provided

build() {
	make
}

package() {
	make DESTDIR="$pkgdir" install
}

sha512sums="
02dc462f8e2d88e090242ac28612e362baabd9d7071a8e9143f6e1d92f8a23ce747fd470fbb795c57d245908de6d42d5540273e755eecbac6c06c1ef26c7ba5c  enjoy-0.3.tar.gz
37e2bc17aadf40e1a3bbbf412f34e51e897bf529121283a025eb7915248f211e5fdeffa4d82e07e816fed666dbcdadd865e59b7980ce5c76e95c7c92b60a08f1  0001-fix-printf-format-specifier.patch
6e89859c5b8752021e1517d2cfdb9a7e9e3bc89098cacbe4845c5ff76aed7b777949efaaeea152ee21a8cdc27112a34b3df2c0015fadc317e756ca626a735791  0002-fix-setting-timestamp-of-input-event.patch
2d4db64553fb184611d1fa3e60fda6db034cccfea57711276e71ffc03a420696d8a7251a74e3e352d275842fa7e543b9e7f146b83cad94d0822d098189cbf37d  correct_udev_rules_path.patch
"
